-- GENERATED SPELL FOR [Winterfall Shaman] --


function spell0_7439(pUnit, Event) --@Healing Touch,Heal--
pUnit:FullCastSpellOnTarget(11431,pUnit)
pUnit:RegisterEvent('Sorts_7439', 3000, 1)
end

function spell1_7439(pUnit, Event) --@Lightning Bolt,n/a--
pUnit:FullCastSpellOnTarget(9532,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_7439', 3000, 1)
end

function spell2_7439(pUnit, Event) --@Lightning Shield,n/a--
pUnit:FullCastSpellOnTarget(13585,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_7439', 0, 1)
end

function spell3_7439(pUnit, Event) --@Winterfall Firewater,Self--
pUnit:FullCastSpellOnTarget(17205,pUnit)
pUnit:RegisterEvent('Sorts_7439', 0, 1)
end

function Sorts_7439(pUnit, Event)
local choix_sorts_7439 = math.random(0, 3)
if choix_sorts_7439 == 0 then
pUnit:RegisterEvent('spell0_7439', 1, 1)
end
if choix_sorts_7439 == 1 then
pUnit:RegisterEvent('spell1_7439', 1, 1)
end
if choix_sorts_7439 == 2 then
pUnit:RegisterEvent('spell2_7439', 1, 1)
end
if choix_sorts_7439 == 3 then
pUnit:RegisterEvent('spell3_7439', 1, 1)
end
end

function mob7439_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_7439', math.random(1500, 3000), 1)
end

function mob7439_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob7439_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob7439_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(7439, 1, 'mob7439_Action')
RegisterUnitEvent(7439, 2, 'mob7439_Leave')
RegisterUnitEvent(7439, 3, 'mob7439_Kill')
RegisterUnitEvent(7439, 4, 'mob7439_Die')
